package router

import (
	"github.com/labstack/echo/v4"
	"longmen/server/internal/api"
	"longmen/server/pkg/common/middlewares"
)

func initActivityRoute(group *echo.Group, base api.Controller, authFunc echo.MiddlewareFunc) {
	//活动
	group.POST("/activity/getActivityProfileList", base.GetActivityProfileList)
	group.POST("/activity/getActivityById", base.GetActivityById)
	group.POST("/activity/getActivityRecord", base.GetActivityRecord, authFunc)       //用户获取活动领取记录
	group.POST("/activity/getActivityRecordNew", base.GetActivityRecordNew, authFunc) //用户获取活动领取记录

	//任务
	group.POST("/task/getTaskList", base.GetTaskList, authFunc)
	group.POST("/task/getRecord", base.GetRecord, authFunc) //任务领取记录

	//签到
	group.POST("/checkin/getCheckinInfo", base.GetCheckinInfo, authFunc)       //获取当日签到信息
	group.POST("/checkin/checkinToday", base.CheckinToday, authFunc)           //今日签到
	group.POST("/checkin/getCheckinHistory", base.GetCheckinHistory, authFunc) //获取历史签到记录

	//vip
	group.POST("/vip/getEplutusOrder", base.GetEplutusOrder, authFunc)
	group.POST("/vip/getVipPriceList", base.GetVipPriceList)

	//抽奖
	group.Use(middlewares.LotteryOperateClickCount)
	group.POST("/lottery/getLottery", base.GetLottery, authFunc)                     //获取抽奖活动信息
	group.POST("/lottery/getAwardBullets", base.GetAwardBullets)                     //获取奖品弹幕列表
	group.POST("/lottery/getLotteryAwardsInfo", base.GetLotteryAwardsInfo, authFunc) //获取抽奖奖品列表信息
	group.POST("/lottery/drawLottery", base.DrawLottery, authFunc)                   //点击抽奖
	group.POST("/lottery/getLotteryHistory", base.GetLotteryHistory, authFunc)       //获取抽奖记录

	//贵族
	group.POST("/noble/getNobleList", base.GetNobleList)
	group.POST("/noble/getNobleById", base.GetNobleById)
	group.POST("/noble/getMyNoble", base.GetMyNoble, authFunc)
	// groupNoble.POST("/noble/getNoblePriceList", base.GetNoblePriceList, authFunc)
	group.POST("/noble/chargeNoble", base.ChargeNoble, authFunc)
	group.POST("/noble/receiveNoble", base.ReceiveNoble, authFunc) // 注册领取贵族

	//红包
	group.POST("/hongBao/getHongBaoSetting", base.GetHongBaoSetting)
	group.POST("/hongBao/provideHongBao", base.ProvideHongBao, authFunc)
	group.POST("/hongBao/grabHongBao", base.GrabHongBao, authFunc)
	group.POST("/hongBao/hongBaoList", base.HongBaoList, authFunc)

}
